In data processing systems, the management of buffer queues is required in many areas. For instance, commands stored for an independently executing processing system will be temporarily stored in buffer queues. Therefore, the supplier of the commands need not provide the commands synchronized with the execution of commands by the independent processing device. However, it must be ensured that the buffer storing these commands temporarily does not overflow or, in a system optimally providing commands, that the buffer queue does not become empty. Traditionally, two techniques have been used to manage buffers. One technique requires that the sender of commands to the buffer query the status of the buffer. In a data processing system where the buffer is tightly coupled to the remainder of the system, this may not be a problem. However, if the buffer is located on a communications bus, the querying of status includes a bus overhead. A second technique is to fill the buffer and wait for the buffer to empty before it is filled again.
One example of an embodiment using the full buffer technique is contained in a paper entitled "Virtual Graphics" by Voorhies, Kirk and Lathrop, published in Computer Graphics, Vol. 22, No. 4, August, 1988. This reference illustrates a first-in/first-out (FIFO) buffer that provides interrupts when the buffer is nearly full by providing an interrupt each time a command is presented to the buffer. This forces the process providing these commands to wait until the buffer is only half full. While this process does regulate the number of commands placed into the buffer, it also generates an excessive number of interrupts.
It is the object of the present invention to provide a buffer manager that minimizes the number of interrupts required while optimally providing entries to the buffer.